home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak Vol F-12
/
(Vol F-12) Jun 02 2012.iso
/
Screensaver
/
screensaver_installer.exe
/
____swmx
/
scripts
/
frame_1
/
DoAction_4.as
< prev
next >
Wrap
Text File
|
2004-10-21
|
10KB
|
279 lines
_global.ScreenweaverSystem = function()
{
this.init();
};
ScreenweaverSystem.prototype.init = function()
{
this.Screen = new ScreenweaverScreen();
this.Dialogs = new ScreenweaverDialogs();
this.Colors = new ScreenweaverColors();
this.Version = new ScreenweaverVersion();
this.Messages = new ScreenweaverMessages();
this.Plugins = new ScreenweaverPlugins();
this.Registry = new ScreenweaverRegistry();
_global.SW_HIDE = 0;
_global.SW_SHOWNORMAL = 1;
_global.SW_NORMAL = 1;
_global.SW_SHOWMINIMIZED = 2;
_global.SW_SHOWMAXIMIZED = 3;
_global.SW_MAXIMIZE = 3;
_global.SW_SHOWNOACTIVATE = 4;
_global.SW_SHOW = 5;
_global.SW_MINIMIZE = 6;
_global.SW_SHOWMINNOACTIVE = 7;
_global.SW_SHOWNA = 8;
_global.SW_RESTORE = 9;
_global.SW_SHOWDEFAULT = 10;
_global.SW_FORCEMINIMIZE = 11;
_global.SW_MAX = 11;
_global.SPI_GETBEEP = 1;
_global.SPI_SETBEEP = 2;
_global.SPI_GETMOUSE = 3;
_global.SPI_SETMOUSE = 4;
_global.SPI_GETBORDER = 5;
_global.SPI_SETBORDER = 6;
_global.SPI_GETKEYBOARDSPEED = 10;
_global.SPI_SETKEYBOARDSPEED = 11;
_global.SPI_LANGDRIVER = 12;
_global.SPI_ICONHORIZONTALSPACING = 13;
_global.SPI_GETSCREENSAVETIMEOUT = 14;
_global.SPI_SETSCREENSAVETIMEOUT = 15;
_global.SPI_GETSCREENSAVEACTIVE = 16;
_global.SPI_SETSCREENSAVEACTIVE = 17;
_global.SPI_GETGRIDGRANULARITY = 18;
_global.SPI_SETGRIDGRANULARITY = 19;
_global.SPI_SETDESKWALLPAPER = 20;
_global.SPI_SETDESKPATTERN = 21;
_global.SPI_GETKEYBOARDDELAY = 22;
_global.SPI_SETKEYBOARDDELAY = 23;
_global.SPI_ICONVERTICALSPACING = 24;
_global.SPI_GETICONTITLEWRAP = 25;
_global.SPI_SETICONTITLEWRAP = 26;
_global.SPI_GETMENUDROPALIGNMENT = 27;
_global.SPI_SETMENUDROPALIGNMENT = 28;
_global.SPI_SETDOUBLECLKWIDTH = 29;
_global.SPI_SETDOUBLECLKHEIGHT = 30;
_global.SPI_GETICONTITLELOGFONT = 31;
_global.SPI_SETDOUBLECLICKTIME = 32;
_global.SPI_SETMOUSEBUTTONSWAP = 33;
_global.SPI_SETICONTITLELOGFONT = 34;
_global.SPI_GETFASTTASKSWITCH = 35;
_global.SPI_SETFASTTASKSWITCH = 36;
_global.SPI_SETDRAGFULLWINDOWS = 37;
_global.SPI_GETDRAGFULLWINDOWS = 38;
_global.SPI_GETNONCLIENTMETRICS = 41;
_global.SPI_SETNONCLIENTMETRICS = 42;
_global.SPI_GETMINIMIZEDMETRICS = 43;
_global.SPI_SETMINIMIZEDMETRICS = 44;
_global.SPI_GETICONMETRICS = 45;
_global.SPI_SETICONMETRICS = 46;
_global.SPI_SETWORKAREA = 47;
_global.SPI_GETWORKAREA = 48;
_global.SPI_SETPENWINDOWS = 49;
_global.SPI_GETHIGHCONTRAST = 66;
_global.SPI_SETHIGHCONTRAST = 67;
_global.SPI_GETKEYBOARDPREF = 68;
_global.SPI_SETKEYBOARDPREF = 69;
_global.SPI_GETSCREENREADER = 70;
_global.SPI_SETSCREENREADER = 71;
_global.SPI_GETANIMATION = 72;
_global.SPI_SETANIMATION = 73;
_global.SPI_GETFONTSMOOTHING = 74;
_global.SPI_SETFONTSMOOTHING = 75;
_global.SPI_SETDRAGWIDTH = 76;
_global.SPI_SETDRAGHEIGHT = 77;
_global.SPI_SETHANDHELD = 78;
_global.SPI_GETLOWPOWERTIMEOUT = 79;
_global.SPI_GETPOWEROFFTIMEOUT = 80;
_global.SPI_SETLOWPOWERTIMEOUT = 81;
_global.SPI_SETPOWEROFFTIMEOUT = 82;
_global.SPI_GETLOWPOWERACTIVE = 83;
_global.SPI_GETPOWEROFFACTIVE = 84;
_global.SPI_SETLOWPOWERACTIVE = 85;
_global.SPI_SETPOWEROFFACTIVE = 86;
_global.SPI_SETCURSORS = 87;
_global.SPI_SETICONS = 88;
_global.SPI_GETDEFAULTINPUTLANG = 89;
_global.SPI_SETDEFAULTINPUTLANG = 90;
_global.SPI_SETLANGTOGGLE = 91;
_global.SPI_GETWINDOWSEXTENSION = 92;
_global.SPI_SETMOUSETRAILS = 93;
_global.SPI_GETMOUSETRAILS = 94;
_global.SPI_SETSCREENSAVERRUNNING = 97;
_global.SPI_GETFILTERKEYS = 50;
_global.SPI_SETFILTERKEYS = 51;
_global.SPI_GETTOGGLEKEYS = 52;
_global.SPI_SETTOGGLEKEYS = 53;
_global.SPI_GETMOUSEKEYS = 54;
_global.SPI_SETMOUSEKEYS = 55;
_global.SPI_GETSHOWSOUNDS = 56;
_global.SPI_SETSHOWSOUNDS = 57;
_global.SPI_GETSTICKYKEYS = 58;
_global.SPI_SETSTICKYKEYS = 59;
_global.SPI_GETACCESSTIMEOUT = 60;
_global.SPI_SETACCESSTIMEOUT = 61;
_global.SPI_GETSERIALKEYS = 62;
_global.SPI_SETSERIALKEYS = 63;
_global.SPI_GETSOUNDSENTRY = 64;
_global.SPI_SETSOUNDSENTRY = 65;
_global.SPI_GETMOUSEHOVERWIDTH = 98;
_global.SPI_SETMOUSEHOVERWIDTH = 99;
_global.SPI_GETMOUSEHOVERHEIGHT = 100;
_global.SPI_SETMOUSEHOVERHEIGHT = 101;
_global.SPI_GETMOUSEHOVERTIME = 102;
_global.SPI_SETMOUSEHOVERTIME = 103;
_global.SPI_GETWHEELSCROLLLINES = 104;
_global.SPI_SETWHEELSCROLLLINES = 105;
_global.SPI_GETSHOWIMEUI = 110;
_global.SPI_SETSHOWIMEUI = 111;
_global.SPI_GETMOUSESPEED = 112;
_global.SPI_SETMOUSESPEED = 113;
_global.SPI_GETSCREENSAVERRUNNING = 114;
_global.SPI_GETACTIVEWINDOWTRACKING = 4096;
_global.SPI_SETACTIVEWINDOWTRACKING = 4097;
_global.SPI_GETMENUANIMATION = 4098;
_global.SPI_SETMENUANIMATION = 4099;
_global.SPI_GETCOMBOBOXANIMATION = 4100;
_global.SPI_SETCOMBOBOXANIMATION = 4101;
_global.SPI_GETLISTBOXSMOOTHSCROLLING = 4102;
_global.SPI_SETLISTBOXSMOOTHSCROLLING = 4103;
_global.SPI_GETGRADIENTCAPTIONS = 4104;
_global.SPI_SETGRADIENTCAPTIONS = 4105;
_global.SPI_GETMENUUNDERLINES = 4106;
_global.SPI_SETMENUUNDERLINES = 4107;
_global.SPI_GETACTIVEWNDTRKZORDER = 4108;
_global.SPI_SETACTIVEWNDTRKZORDER = 4109;
_global.SPI_GETHOTTRACKING = 4110;
_global.SPI_SETHOTTRACKING = 4111;
_global.SPI_GETFOREGROUNDLOCKTIMEOUT = 8192;
_global.SPI_SETFOREGROUNDLOCKTIMEOUT = 8193;
_global.SPI_GETACTIVEWNDTRKTIMEOUT = 8194;
_global.SPI_SETACTIVEWNDTRKTIMEOUT = 8195;
_global.SPI_GETFOREGROUNDFLASHCOUNT = 8196;
_global.SPI_SETFOREGROUNDFLASHCOUNT = 8197;
};
ScreenweaverSystem.prototype.shellMailTo = function(address, subject, body)
{
var mailto = "mailto:";
if(address != undefined)
{
mailto += address;
if(subject != undefined)
{
mailto += "?subject=" + escape(subject);
if(body != undefined)
{
mailto += "&body=" + escape(body);
}
}
}
swSystem.shellOpenDocument(mailto);
};
ScreenweaverSystem.prototype.getMonitorModes = function()
{
var i = 0;
while(i < swSystem.data.monitorCount)
{
swInterface.callMethod("requestScreenData",i,swSystem.onMonitorModes);
i++;
}
};
ScreenweaverSystem.prototype.onMonitorModes = function(success, m)
{
swSystem.data.monitors[m.info.number] = m;
if(m.info.number == swSystem.data.monitorCount - 1)
{
swEvents.broadcastMessage("onMonitorModes");
}
};
ScreenweaverSystem.prototype.shellExecute = function(operation, filename, parameters, directory, showCmd, callback, scope)
{
var args = {nShowCmd:int(showCmd),lpDirectory:directory,lpParameters:parameters.toString(),lpFile:filename,lpVerb:operation,hHandle:swWindow.data.HostHandle};
swInterface.callDLLMethod("shell32.dll","ShellExecuteA",args,callback,scope);
};
ScreenweaverSystem.prototype.shellOpenApplication = function(filename, parameters, showCmd, callback, scope)
{
swSystem.shellExecute("open",filename,parameters,"",showCmd,callback,scope);
};
ScreenweaverSystem.prototype.shellOpenDocument = function(filename, callback, scope)
{
swSystem.shellExecute("open",filename,"","",1,callback,scope);
};
ScreenweaverSystem.prototype.shellPrint = function(filename, callback, scope)
{
swSystem.shellExecute("print",filename,"","",1,callback,scope);
};
ScreenweaverSystem.prototype.shellExplore = function(folder, callback, scope)
{
swSystem.shellExecute("explore",folder,"","",1,callback,scope);
};
ScreenweaverSystem.prototype.shellFind = function(folder, callback, scope)
{
swSystem.shellExecute("find",folder,"","",1,callback,scope);
};
ScreenweaverSystem.prototype.shellEdit = function(filename, callback, scope)
{
swSystem.shellExecute("edit",filename,"","",1,callback,scope);
};
ScreenweaverSystem.prototype.getPlayerPath = function(addPath)
{
if(swApplication.Data.EngineLoaded)
{
var index = swApplication.Data.EnginePath.lastIndexOf("\\");
if(index != -1)
{
return swApplication.Data.EnginePath.substr(0,index + 1) + addPath;
}
this.apiError("Path is invalid: " + swApplication.Data.EnginePath);
}
return "[ The swInterface engine didn\'t properly load. ]";
};
ScreenweaverSystem.prototype.getWindowsDirectory = function()
{
return swSystem.data.dirWindows;
};
ScreenweaverSystem.prototype.getSystemDirectory = function()
{
return swSystem.data.dirSystem;
};
ScreenweaverSystem.prototype.getFlashPluginPath = function()
{
if(swSystem.data.pathFlashPlugin == undefined)
{
return "[OCX Path is unknown]";
}
return swSystem.data.pathFlashPlugin;
};
ScreenweaverSystem.prototype.getUserName = function()
{
return swSystem.data.UserName;
};
ScreenweaverSystem.prototype.getComputerName = function()
{
return swSystem.data.ComputerName;
};
ScreenweaverSystem.prototype.setClipboardText = function(text)
{
getURL("FSCommand:sw_setClipboardText",text);
};
ScreenweaverSystem.prototype.getClipboardText = function(callback, scope)
{
args = {};
swInterface.callMethod("getClipboardText",args,callback,false,scope);
};
ScreenweaverSystem.prototype.registerWindowMessage = function(message, handler, handlerScope, callback, scope)
{
args = {message:message,CallbackID:swInterface.addCallback(handler,true,handlerScope)};
swInterface.callMethod("registerWindowMessage",args,callback,false,scope);
};
ScreenweaverSystem.prototype.getMouse = function(callback, scope)
{
args = {};
swInterface.callMethod("GetMouseXY",args,callback,false,scope);
};
ScreenweaverSystem.prototype.getEnvironmentVar = function(variable, callback, scope)
{
args = {variable:variable.toString()};
swInterface.callMethod("GetEnvironmentVar",args,callback,false,scope);
};